#pragma once

#include "GL/glew.h"
#include "GL/glut.h"

const GLdouble bias[16] = {	
		0.5, 0.0, 0.0, 0.0, 
		0.0, 0.5, 0.0, 0.0,
		0.0, 0.0, 0.5, 0.0,
        0.5, 0.5, 0.5, 1.0};

class ShadowMap
{
private:
    int size;
public:
    GLuint frameBuffer;
    GLuint depthBuffer;
    GLuint depthTexture;

    ShadowMap(int size);

    void preRender(double x, double y, double z);

    void postRender(GLenum texture);

    void setTextureMatrix(GLenum texture);
};
